package com.example.ka;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;

import androidx.appcompat.app.AppCompatActivity;



public class menu extends AppCompatActivity {
    Button btn_dangban,btn_shouyin,btn_jiaoban,btn_jiaohuan,btn_pandian,btn_shezhi,btn_lianxi,btn_kaoqin,btn_buhuo,btn_tuichu;
    @Override
    protected void onCreate( Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_menu);
        Toast.makeText(menu.this,"欢迎您！",Toast.LENGTH_LONG).show();
        btn_dangban = findViewById(R.id.dangban);
        btn_dangban.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,dangban.class);
            startActivity(intent);
        });
        btn_shouyin = findViewById(R.id.shouyin);
        btn_shouyin.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,shouyin.class);
            startActivity(intent);
        });
        btn_jiaoban = findViewById(R.id.jiaoban);
        btn_jiaoban.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,jiaoban.class);
            startActivity(intent);
        });
        btn_jiaohuan = findViewById(R.id.jiaohuan);
        btn_jiaohuan.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,jiaohuan.class);
            startActivity(intent);
        });
        btn_pandian = findViewById(R.id.pandian);
        btn_pandian.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,pandian.class);
            startActivity(intent);
        });
        btn_shezhi = findViewById(R.id.shezhi);
        btn_shezhi.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,shezhi.class);
            startActivity(intent);
        });
        btn_lianxi = findViewById(R.id.lianxi);
        btn_lianxi.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,lianxi.class);
            startActivity(intent);
        });
        btn_kaoqin = findViewById(R.id.kaoqin);
        btn_kaoqin.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,kaoqin.class);
            startActivity(intent);
        });
        btn_buhuo = findViewById(R.id.buhuo);
        btn_buhuo.setOnClickListener(view -> {
            Intent intent = new Intent(menu.this,buhuo.class);
            startActivity(intent);
        });
        btn_tuichu = findViewById(R.id.tuichu);
        btn_tuichu.setOnClickListener(this::click);
    }

    public void click(View view){
        finish();
    }
}
